<!-- /  www.bdr130.net            -   -->
<script type="text/javascript">
function insertHTML() {
var SelectColor = "background-color:white;color:black";
document.write('<select style="' + SelectColor + ';font-family:MS Sans Serif;font-size:8pt" onchange="Editor_addCodealbahoot(\'\'+this[this.selectedIndex].value+\'\',\'\');this.selectedIndex=0">');
document.write('<option selected> </option>');
document.write('<option value="    \n"></option>');
document.write('<option value="   \n"></option>');
document.write('<option value="   "></option>');
document.write('<option value="           \n">  </option>');
document.write('<option value="   ,   \n"></option>');
document.write('<option value=" "></option>');
document.write('<option value="  \n"></option>');
document.write('</select>'),
document.write('&nbsp;');
document.write('<select style="' + SelectColor + ';font-family:MS Sans Serif;font-size:8pt" onchange="Editor_addCode(\'\'+this[this.selectedIndex].value+\'\',\'\'+this[this.selectedIndex].value+\'\',\'\');this.selectedIndex=0">');
document.write('<option selected> </option>');
document.write('<option value="......">......</option>');
document.write('<option value="][][^][][">][][^][][</option>');
document.write('<option value="][`~*!||!*~`][">][`~*!||!*~`][</option>');
document.write('<option value="~*(**)*~">~*(**)*~</option>');
document.write('<option value="^&)^^(&^">^&)^^(&^</option>');
document.write('<option value="*~-.,.-~*">*~-.,.-~*</option>');
document.write('<option value="?"?`"?">?"?`"?</option>');
document.write('<option value="|--**--|">|--**--|</option>');
document.write('<option value="~**~">~**~</option>');
document.write('<option value="~**~**~">~**~**~</option>');
document.write('<option value="|,,|">|,,|</option>');
document.write('<option value="][][^][][">][][^][][</option>');
document.write('<option value="~~">~~</option>');
document.write('<option value="~~">~~</option>');
document.write('</select>');
document.write('&nbsp;');
document.write('<select style="' + SelectColor + ';font-family:MS Sans Serif;font-size:8pt" onchange="Editor_addCode(\'[size=\'+this[this.selectedIndex].value+\']\',\'[/size]\');this.selectedIndex=0">');
document.write('<option selected> </option>');
document.write('<option value="1">1</option>');
document.write('<option value="2">2</option>');
document.write('<option value="3">3</option>');
document.write('<option value="4">4</option>');
document.write('<option value="5">5</option>');
document.write('<option value="6">6</option>');
document.write('<option value="7">7</option>');
document.write('</select> ');
document.write('&nbsp;');
document.write('<select style="' + SelectColor + ';font-family:MS Sans Serif;font-size:8pt" onchange="Editor_addCode(\'[font=\'+this[this.selectedIndex].value+\']\',\'[/font]\');this.selectedIndex=0">');
document.write('<option selected> </option>');
document.write('<option value="Arial">Arial</option>');
document.write('<option value="Arial Black">Arial Black</option>');
document.write('<option value="Arial Narrow">Arial Narrow</option>');
document.write('<option value="Comic Sans MS">Comic Sans MS</option>');
document.write('<option value="Courier New">Courier New</option>');
document.write('<option value="System">System</option>');
document.write('<option value="Tahoma">Tahoma</option>');
document.write('<option value="Times New Roman">Times New Roman</option>');
document.write('<option value="Simplified Arabic">Simplified Arabic</option>');
document.write('<option value="Verdana">Verdana</option>');
document.write('<option value="Wingdings">Wingdings</option>');
document.write('</select>&nbsp;');
document.write('&nbsp;');
}
var buttons = new Array();
function addRow(a) {
buttons = buttons.concat("*");
buttons = buttons.concat(a);
}
function showButtons() {
addRow (new Array("cut|","copy|","paste|","delete|","keyb|   ","plain| ","ltr|     ","rtl|     ","bold|","italic|","uline| ","strike| ","overline| ","left| ","center|","right| ","justify|  ","mklb|  ","mklb1|  ","motfrk|     :    ","a7la1|  "));
addRow (new Array("link| ","email| ","smile|  ","image|","bimg|   ","lon|   ","color| ","mark| ","php| php","code|","quote|","list|","poem|  ","frame| ","glow| ","blink|","glint|","gradient| ","rplayer|    (rm,ra,ram,...)","media|    (mp3,wav,au,wma,mpg,mpeg,wmv,avi,...)","flash|   (swf)"));
addRow (new Array("mleft|   ","mright|   ","mup|   ","mdown|   ","kleft|       ","kright|       ","kup|       ","kdown|       ","tleft|   ","tright|   ","tup|   ","tdown|   ","oleft|       ","oright|       ","oup|       ","odown|       ","msg|        ","button|           ","3mr|  ","flash1| ","cc|   "));
addButtons(buttons, 0);
buttons = null;
}
var tip = "   Version :4    :  ";
var keyboardColor,statusColor,tipColor;
var btn_backcolor_over, btn_backcolor_down, btn_bordercolor;
var toolbox_background,toolbox_backcolor;
var btn_obj = "";
function Capture(b) {
if (document.activeElement.name != "message") {
return;
}
if (event.srcElement.tagName.toLowerCase() == "select")
return;
if (btn_obj) {
btn_obj.releaseCapture();
btn_obj = "";
} else if (b == 1) {
btn_obj = event.srcElement;
btn_obj.setCapture();
}
}
function button_over(eButton, w) {
if (w == "qkeys") {
eButton.parentElement.background = "images/toolbox/key_2.gif";
eButton.style.color = "white";
} else {
vbform.toolboxbar.style.color = statusColor;
vbform.toolboxbar.value = w;
doButton(btn_backcolor_over, 1, eButton);
}
}
function button_out(eButton, w) {
if (w == "qkeys") {
eButton.parentElement.background = "transparent";
eButton.style.color = "black";
} else {
vbform.toolboxbar.style.color = tipColor;
vbform.toolboxbar.value = tip;
doButton("transparent", 0, eButton);
}
}
function button_down(eButton, w) {
if (w != "qkeys")
doButton(btn_backcolor_down, 1, eButton);
}
function button_up(eButton, w) {
if (w != "qkeys")
doButton(btn_backcolor_over, 1, eButton);
eButton = null;
}
function doButton(bk, s, btn) {
if (event.button == 2) return;
btn.style.backgroundColor = bk;
if (s == 0)	{
btn.parentElement.style.backgroundColor = "transparent";
} else {
btn.parentElement.style.backgroundColor = btn_bordercolor;
}
}
function do_button(c) {
var bn, ob, k;
ob = window.event.srcElement;
if (bn=ob.tag) {
if (bn.indexOf("|||") >= 0) {
if (ob.tagName == "IMG")
ob = ob.parentElement;
bn = bn.split("|||");
if (c == 1) //click
execTool(bn[0]);
else if (c == 2) //mouse over
button_over(ob, bn[1]);
else if (c == 3) //mouse out
button_out(ob, bn[1]);
else if (c == 4) //mouse down
button_down(ob, bn[1]);
else if (c == 5) //mouse up
button_up(ob, bn[1]);
}
}
}
function addKeys(buttons) {
var tbl, newRow;
document.write('<table onclick="do_button(1)" onmouseover="do_button(2)" onmouseout="do_button(3)" onmousedown="do_button(4)" onmouseup="do_button(5)" dir="rtl" id="keyboardTable" border="0" cellpadding="0" cellspacing="0" width="1px" style="display:none">');
document.write('<tr><td>');
newRow = 1;
for (var i = 0; i < buttons.length; i++) {
if (i % 15 == 0) {
document.write('<table dir="rtl" align="center" background="images/toolbox/key_1.gif" border="0" cellpadding="0" cellspacing="0" width="1px"><tr>');
newRow = 0;
}
tbl = '<td height="29px"><div style="font-size:x-small;font-family:arial;font-weight:bold;cursor:hand;text-align:center;width:30px;height:20px;color:black" tag="qkeys_' + buttons[i] + '|||qkeys">';
if (buttons[i] == " ")
buttons[i] = "&nbsp;";
tbl += buttons[i] + '</div>';
tbl += '</td>';
document.write(tbl);
if ((i + 1) % 15 == 0) {
document.write('</tr></table>');
newRow = 1;
}
}
if (newRow == 0) {
document.write('</tr></table>');
}
document.write('</td></tr></table>');
}
function addButtons(buttons) {
var tbl, bn, newRow;
document.write('<table onclick="do_button(1)" onmouseover="do_button(2)" onmouseout="do_button(3)" onmousedown="do_button(4)" onmouseup="do_button(5)" bgcolor="' + toolbox_backcolor + '" background="' + toolbox_background + '" dir="ltr" border="0" cellpadding="0" cellspacing="0" width="1px" style="border:1px ridge">');
document.write('<tr><td align="left">');
document.write('<table dir="ltr" border="0" cellpadding="0" cellspacing="0" width="100%" style="border:1px ridge" height=20px><tr><td align="right">');
insertHTML();
document.write('</td></tr></table>');
newRow = 1;
for (var i = 0; i < buttons.length; i++) {
if (buttons[i] == "*") {
if (newRow == 0) {
document.write('</tr></table>');
document.write('</td></tr></table>');
newRow = 1;
}
continue;
}
if (newRow) {
document.write('<table dir="ltr" border="0" cellpadding="0" cellspacing="0" width="1px" style="merge:5px;"><tr><td style="border:1px ridge;padding-right:10px;padding-left:10px">');
document.write('<table align="left" width="1px" border="0" cellpadding="0" cellspacing="0"><tr>');
newRow = 0
}
if (buttons[i] == "") {
tbl = '</tr></table><td style="border:1px ridge;padding-right:5px;padding-left:5px">';
tbl += '<table align="left" width="1px" border="0" cellpadding="0" cellspacing="0"><tr>';
} else if (buttons[i] == " ") {
tbl = '<td style="padding:1px"><div class="cbtn" style="font-size:1pt">&nbsp;';
} else {
bn = buttons[i] + "| ";
bn = bn.split("|");
tbl = '<td style="padding:1px"><div align="center" class="cbtn" tag="' + bn[0] + '|||' + bn[1] + '">';
tbl += '<img tag="' + bn[0] + '|||' + bn[1] + '" border="0" align="absmiddle" width="18px" height="18px" src="images/toolbox/' + bn[0] + '.gif" alt="' + bn[1] + '">';
}
tbl += '</div></td>';
document.write(tbl);
}
if (newRow == 0) {
document.write('</tr></table>');
document.write('</td></tr></table>');
}
document.write('<table dir="rtl" border="0" cellpadding="0" cellspacing="0" width="100%" style="border:1px ridge"><tr>');
document.write('<td width="1px"><img border="0" align="middle" src="images/toolbox/tip.gif"></td>');
document.write('<td><input type="text" name="toolboxbar" value="' + tip + '" style="height:15px;border-style:none;width:100%;font:8pt tahoma ;background-color:transparent;color:' + tipColor + '"></td></tr>');
document.write('</table>');
document.write('</td></tr></table>');
}
function showKeyboard() {
var buttons = new Array("","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","",""," "," ","","","","");
addKeys(buttons);
}
function showColorsWindow() {
var posX = event.screenX;
var posY = event.screenY + 5;
var screenW = screen.width; // screen size
var screenH = screen.height - 20; // take taskbar into account
if (posX + 232 > screenW) { posX = posX - 232 - 40; } // if mouse too far right
if (posY + 164 > screenH) { posY = posY - 164 - 80; } // if mouse too far down
var wPosition = "dialogLeft:" +posX+ "; dialogTop:" +posY;
return showModalDialog("massy/colors.html", "",
"dialogWidth:238px; dialogHeight: 195px; resizable: no; help: no; status: no; scroll: no; "	+ wPosition);
}
function execTool(btn) {
if (event.altKey) {
if (btn.substr(0,6) != "qkeys_") {
open("help.php?toolsel=" + btn, "help", "toolbar=no,scrollbars=yes,resizable=yes,width=550px,height=350px,left=50px,top=100px");
}
} else
EditorFunctions(btn);
}
function Editor_getSelText() {
var oSelect,oSelectRange;
document.vbform.message.focus();
oSelect = document.selection;
oSelectRange = oSelect.createRange();
return oSelectRange;
}
function Editor_addCode(tag1,tag2) {
var oSelText = Editor_getSelText();
if (oSelText.text == "")
alert("   ");
else
oSelText.text = tag1 + oSelText.text + tag2;
}
function Editor_addCodealbahoot(tag1,tag2) {
var oSelText = Editor_getSelText();
oSelText.text = tag1 + oSelText.text + tag2;
}
function EditorFunctions(tag) {
if (tag.substr(0, 6) == "qkeys_") { // Arabic Keyboard
var oSelText = Editor_getSelText();
tag = tag.substr(6);
if (tag == "") tag = "";
oSelText.text = tag;
}
else if (tag == "rtl" || tag == "ltr") {
document.vbform.message.dir=tag.substr(tag);
}
else if (tag == "bold") {
Editor_addCode("[B]","[/B]");
}
else if (tag == "italic") {
Editor_addCode("[I]","[/I]");
}
else if (tag == "uline") {
Editor_addCode("[U]","[/U]");
}
else if (tag == "line") {
var oSelText = Editor_getSelText();
oSelText.text = "[line][/line]";
}
else if (tag == "quote") {
Editor_addCode("[quote]","[/quote]");
}
else if (tag == "code") {
Editor_addCode("[code]","[/code]");
}
else if (tag == "php") {
Editor_addCode("[php]","[/php]");
}
else if (tag == "html") {
Editor_addCode("[html]","[/html]");
}
else if (tag == "overline") {
Editor_addCode("[overline]","[/overline]");
}
else if (tag == "strike") {
Editor_addCode("[S]","[/S]");
}
else if (tag == "mklb1") {
Editor_addCode("[mklb1]","[/mklb1]");
}
else if (tag == "mklb") {
Editor_addCode("[mklb]","[/mklb]");
}
else if (tag == "motfrk") {
Editor_addCode("[motfrk]","[/motfrk]");
}
else if (tag == "msg") {
Editor_addCode("[msg]","[/msg]");
}
  else if (tag == "smile") {
  	  window.open("misc.php?do=getsmilies&editorid=vB_Editor_001", "smilies", "toolbar=no,status=no,scrollbars=yes,resizable=yes,width=440px,height=280px");
  }
else if (tag=="lon") {
var oSelText = Editor_getSelText();
if (oSelText.parentElement().name=="message")
showModalDialog("massy/colo.htm",oSelText,"help:no; center:yes; status:no; dialogHeight:319px; dialogWidth:457px");
}
else if (tag == "flash1") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("    :", link);
if (!ob) return;
var w = window.prompt("     :","400");
if (!w) return;
var h = window.prompt("     :","350");
if (!h) return;
oSelText.text = "[flash1="+ob+"]WIDTH="+w+" HEIGHT="+h+"[/flash1]";
}

else if (tag == "cc") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
var ob = window.prompt("   :","     ");
if (ob)
if (oSelText.text=="")
oSelText.text = "[cc]"+ob+"[/cc]";
else
oSelText.text = "[cc="+ob+"]"+oSelText.text +"[/cc]";
}

else if (tag == "3mr") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
var ob = window.prompt("   :","backgrounds/16.gif");
if (ob)
if (oSelText.text=="")
oSelText.text = "[3mr]"+ob+"[/3mr]";
else
oSelText.text = "[3mr="+ob+"]"+oSelText.text +"[/3mr]";
}
else if (tag == "button") {
var oSelText = Editor_getSelText();
var ob = window.prompt("      :","            ");
txt = oSelText.text;
if (ob) {
if (txt=="")
txt = window.prompt("         ","           ");
if (txt)
oSelText.text = "[button="+ob+"]"+txt+"[/button]";
else
oSelText.text = "[button]"+ob+"[/button]";
}
}
else if (tag == "gradient") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
code = showModalDialog("massy/gradient_form.htm","","help:no; center:yes; status:no; dialogHeight:150px; dialogWidth:420px");
if (!code)
return;
oSelText.text = "[grade=\"" + code + "\"]" + oSelText.text + "[/grade]"
}
else if (tag == "left" || tag == "center" || tag == "right" || tag == "justify") {
Editor_addCode("[align="+tag.toLowerCase()+"]","[/align]");
}
else if (tag == "link") {
var oSelText = Editor_getSelText();
var ob = window.prompt(" :","http://");
txt = oSelText.text;
if (ob) {
if (txt=="")
txt = window.prompt("   ","");
if (txt)
oSelText.text = "[url="+ob+"]"+txt+"[/url]";
else

oSelText.text = "[url]"+ob+"[/url]";
}
}
else if (tag == "email") {
var oSelText = Editor_getSelText();
var ob = window.prompt("   :","@");
if (ob)
if (oSelText.text=="")
oSelText.text = "[email]"+ob+"[/email]";
else
oSelText.text = "[email="+ob+"]"+oSelText.text +"[/email]";
}
else if (tag == "image") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("  :",link);
if (ob)
oSelText.text = "[img]"+ob+"[/img]";
}
else if (tag == "bimg") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("    :",link);
if (ob)
oSelText.text = "[bimg]"+ob+"[/bimg]";
}
else if (tag == "mleft" || tag == "mright" || tag == "mup" || tag == "mdown") {
Editor_addCode("[move="+tag.substr(1).toLowerCase()+"]","[/move]");
}
else if (tag == "tleft" || tag == "tright" || tag == "tup" || tag == "tdown") {
Editor_addCode("[movet="+tag.substr(1).toLowerCase()+"]","[/movet]");
}
else if (tag == "oleft" || tag == "oright" || tag == "oup" || tag == "odown") {
Editor_addCode("[moveo="+tag.substr(1).toLowerCase()+"]","[/moveo]");
}
else if (tag == "kleft" || tag == "kright" || tag == "kup" || tag == "kdown") {
Editor_addCode("[movek="+tag.substr(1).toLowerCase()+"]","[/movek]");
}
else if (tag == "sleft" || tag == "sright" || tag == "sup" || tag == "sdown") {
Editor_addCode("[moves="+tag.substr(1).toLowerCase()+"]","[/moves]");
}
else if (tag == "rplayer") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("    :", link);
if (ob) {
t = window.prompt("  = 0\r\n = 1", 0);
if (t) {
if (t==0)
oSelText.text = "[rams]"+ob+"[/rams]";
else
oSelText.text = "[ramv]"+ob+"[/ramv]";
}
}
}
else if (tag == "media") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("   :", link);
if (ob)
oSelText.text = "[media]"+ob+"[/media]";
}
else if (tag == "flash") {
var oSelText = Editor_getSelText();
var link=((oSelText.text=="")?"http://":oSelText.text);
var ob = window.prompt("   :", link);
if (!ob) return;
var w = window.prompt("     :","400");
if (!w) return;
var h = window.prompt("     :","350");
if (!h) return;
oSelText.text = "[flash="+ob+"]WIDTH="+w+" HEIGHT="+h+"[/flash]";
}
else if (tag == "poem") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("ǡ\n    .         (=)");
return;
}
code = showModalDialog("massy/poem_form.htm","","help:no; center:yes; status:no; dialogHeight:450px; dialogWidth:560px");
if (!code)
return;
oSelText.text = "[poem= " + code + "]\n" + oSelText.text + "[/poem]"
}
else if (tag == "frame") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
code = showModalDialog("massy/frame_form.htm","","help:no; center:yes; status:no; dialogHeight:290px; dialogWidth:450px");
if (!code)
return;
oSelText.text = '[frame="' + code + '"]' + oSelText.text + '[/frame]';
}
else if (tag == "foasl") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
code = showModalDialog("massy/insert_image.html","","help:no; center:yes; status:no; dialogHeight:290px; dialogWidth:450px");
if (!code)
return;
oSelText.text = '[foasl]' + oSelText.text + '[/foasl]';
}
else if (tag == "plain") {
var oSelText = Editor_getSelText();
if (oSelText.parentElement().name=="message") {
var temp = oSelText.text;
temp = temp.replace(/\[FLASH=([^\]]*)\]WIDTH=[0-9]{0,4} HEIGHT=[0-9]{0,4}\[\/FLASH\]/gi,"$1");
temp = temp.replace(/\[VIDEO=([^\]]*)\]WIDTH=[0-9]{0,4} HEIGHT=[0-9]{0,4}\[\/VIDEO\]/gi,"$1");
oSelText.text = temp.replace(/\[[^\]]*\]/gi,"");


}
}
else if (tag == "list") {
Editor_addCode("[list]\n","\n[/list]");
}
else if (tag == "blink") {
Editor_addCode("[blink]","[/blink]");
}
else if (tag == "glint") {
Editor_addCode("[glint]","[/glint]");
}
else if (tag == "cut" || tag == "copy" || tag == "paste" || tag == "delete") {
var oSelText = Editor_getSelText();
oSelText.execCommand(tag);
}
else if (tag == "keyb") {
if (keyboardTable.style.display == "none") {
event.srcElement.src = "images/toolbox/keybx.gif";
keyboardTable.style.display = "inline";
event.srcElement.alt = "   ";
}
else {
event.srcElement.src = "images/toolbox/keyb.gif";
keyboardTable.style.display = "none";
event.srcElement.alt = "   ";
}
}
else if (tag == "colorpicker") {
var c = showColorsWindow();
if (c) {
var oSelText = Editor_getSelText();
oSelText.text = c;
}
} else if (tag == "glow" || tag == "mark" || tag == "color"|| tag == "a7la1") {
var oSelText = Editor_getSelText();
if (oSelText.text == "") {
alert("   ");
return;
}
var c = showColorsWindow();
if (c) {
oSelText.text = "[" + tag + "=" + c + "]" + oSelText.text + "[/" + tag + "]";
}
} else if (tag == "help") {
open("help.php", "help", "toolbar=no,scrollbars=yes,resizable=yes,width=550px,height=350px,left=50px,top=100px");
}
}
</script>
<script language="Javascript">
toolbox_backcolor = "#DADEDD";
toolbox_background ="backgrounds/33.gif";
btn_bordercolor = "black";
btn_backcolor_over = "cornsilk";
btn_backcolor_down = "white";
statusColor = "black";
tipColor = "maroon";
</script>
<STYLE TYPE="text/css">
.cbtn{
  width:20px;
  height:18px;
  cursor:hand;
}
</STYLE>
<table dir="ltr" border="0" cellpadding="1" cellspacing="1" width="100%">
<tr><td align="center" oncontextmenu="return false" onselectstart="return false" 
onmousedown="Capture(1)" onmouseup="Capture(0)" onmousemove="Capture(0)">
<script language="javascript">
showButtons();
showKeyboard();
</script>
</td></tr></table>
<div class="controlbar" style="text-align:$stylevar[left]">
<textarea name="message" rows="20" cols="60" wrap="virtual" style="width:$stylevar[messagewidth]; height:250px" 
tabindex="1">$newpost[message]</textarea>
</div>
<!-- /  www.bdr130.net            -   -->